.TH lgtenv 1 "May 2, 2025" "Logtalk 3.92.0" "Logtalk Documentation"

.SH NAME
lgtenv \- Logtalk script for creating packs virtual environments

.SH SYNOPSIS
.B lgtenv -v
.br
.B lgtenv
[\fB-d \fIdirectory\fR]
[\fB-c\fR]
[\fB-p \fIpacks\fR]
.br
.B lgtenv -h

.SH DESCRIPTION
\fBlgtenv\fR is a Logtalk script for creating packs virtual environments. It works by activating a \fBLOGTALKPACKS\fR environment variable when changing the current directory to the directory where the virtual environment was created. To use the virtual environment, start Logtalk from the directory where the virtual environment was created.

.SH OPTIONS
.TP
.BI \-d
Directory where to create the virtual environment. Absolute path. Default is the current directory.
.TP
.BI \-c
Create directory if it does not exist.
.TP
.BI \-p
Packs sub-directory. Relative path. Default is the current directory.

.SH "EXIT STATUS"
.TP
.B 0
Success.
.TP
.B 1
Usage error.
.TP
.B 3
Directory not found.
.TP
.B 5
Directory not writable.
.TP
.B 7
Dependency \fBdirenv\fR not found.

.SH REQUIREMENTS
Requires \fBdirenv\fR to be installed (see https://github.com/direnv/direnv).

.SH ENVIRONMENT
.TP
.B LOGTALKHOME
Specifies the location of the Logtalk installation.
.TP
.B LOGTALKUSER
Specifies the location of the Logtalk user directory.

.SH "SEE ALSO"
The Logtalk website at https://logtalk.org/
.PP
The Logtalk Handbook at \fB$LOGTALKHOME/docs/handbook/index.html\fR

.SH AUTHOR
Paulo Moura <pmoura@logtalk.org>

.SH COPYRIGHT
Copyright (c) 2023-2025 Paulo Moura.
